package queuedemo;

import java.util.Deque;
import java.util.LinkedList;
import java.util.Queue;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * Date: 2025-01-24
 * Time: 22:22
 */
public class Test {
    public static void main(String[] args) {
        Deque<Integer> deque = new LinkedList<>();

        deque.offerFirst(12);
        deque.pollLast();


        Deque<Integer> stack = new LinkedList<>();
        stack.push(10);
    }
    public static void main2(String[] args) {
        MyQueue queue = new MyQueue();

        queue.offer(12);
        queue.offer(23);
        queue.offer(34);
        queue.offer(45);

        System.out.println(queue.poll());
        System.out.println(queue.peek());
    }

    public static void main1(String[] args) {
        Queue<Integer> queue = new LinkedList<>();

        queue.offer(12);
        queue.offer(23);
        queue.offer(34);
        queue.offer(45);
        queue.offer(56);

        System.out.println(queue.poll());
        System.out.println(queue.peek());
    }
}
